home *** CD-ROM | disk | FTP | other *** search
/ Loadstar 46 / 046.d81 / easy keys (.txt) < prev    next >
Encoding:
Commodore BASIC  |  1988-01-01  |  1.4 KB  |  39 lines

  1. 100 rem easy keys
  2. 110 rem by steve goldsmith
  3. 120 rem 1984
  4. 130 poke53280,14:poke53281,12:print"[147][144]               easy keys                "
  5. 140 print"type in the commands you want the       functions keys to represent."
  6. 150 dimf$(8):tx=49408:open1,0:gosub280
  7. 160 fora=1to8:print"function "a":":al=1:nu=1:le=38:gosub60500
  8. 180 f$(a)=c$
  9. 190 print:print"auto return (y/n): ";
  10. 200 b=peek(203):ifb<>25andb<>39then200
  11. 210 ifb=25thenprint"y":f$(a)=f$(a)+chr$(13):goto230
  12. 220 print"n":f$(a)=f$(a)+chr$(0):goto230
  13. 230 print:next
  14. 240 print"[147]easy keys          compiling information"
  15. 250 fora=1to8:hi=int(tx/256):lo=tx-hi*256:poke49152+(a-1)*2,lo
  16. 260 poke49153+(a-1)*2,hi:readb:forc=1tolen(f$(b))
  17. 270 poketx,asc(mid$(f$(b),c,1)):tx=tx+1:next:next:sys49168:new
  18. 280 fora=0to106:readb:poke49168+a,b:next:return
  19. 290 rem machine language program
  20. 300 data169,0,133,255,120,169,33,141,20,3,169,192,141,21,3,88,96,165,255,208,50
  21. 310 data165,197,201,3,144,4,201,7,144,3,76,49,234,173,141,2,240,7,165,197,24,105
  22. 320 data1,208,5,165,197,56,233,3,10,170,189,0,192,133,251,189,1,192,133,252,169
  23. 330 data0,133,254,169,1,133,255,164,254,177,251,240,11,201,13,208,14,141,119,2
  24. 340 data169,1,133,198,169,0,133,255,76,49,234,141,119,2,169,1,133,198,230,254
  25. 350 data76,49,234
  26. 360 rem function key evaluation
  27. 370 data7,1,3,5,8,2,4,6
  28. 60500 c$="":poke198,.:print"[164]";
  29. 60510 forc=1tole+1
  30. 60520 geta$:ifa$=""then60520
  31. 60530 ifa$=chr$(13)thenprint"[157] ":return
  32. 60540 ifa$=chr$(20)andc>1thenprint"[157][157]  [157][157][164]";:c=c-1:c$=left$(c$,c-1):goto60520
  33. 60550 if(c=le+1)then60520
  34. 60560 if(nu)and((a$>="0")and(a$<="9"))then60595
  35. 60570 if(al)and((a$>=" "anda$<="/")or(a$>=":"anda$<="z"))then60595
  36. 60580 if(al)thenif(a$>="[193]"anda$<="[218]")then60595
  37. 60590 goto60520
  38. 60595 print"[157]"a$;:poke212,.:print"[164]";:c$=c$+a$:next
  39.